﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework.Graphics;
using GameBase;

namespace GalaxyPresident
{
    class MoonView : MutiSpriteObject
    {
        protected static Texture2D MOON_TEXTURE =
            Constant.content.Load<Texture2D>(@"Resources/moon");
        Moon moon;
        public MoonView(Moon moon)
        {
            this.moon = moon;
            Sprite spriteMoon = new Sprite(MOON_TEXTURE, 1, 1);
            spriteMoon.SetOriginPosition(ORIGIN_POSITION.Center);
            spriteMoon.Color = moon.BackColor;
            Scale = moon.Diameter / spriteMoon.Width;
            AddSprite(spriteMoon);
            position = moon.Position;
            Depth = 0.11f;
        }
        public override void Update(Microsoft.Xna.Framework.GameTime gameTime)
        {
            base.Update(gameTime);
            position = moon.Position/1.5f;
        }
    }
}
